/*
 * @Descripttion: GGB
 * @version: 1.0
 * @Author: GGB
 * @Date: 2021-08-12 09:59:56
 * @LastEditors: GGB
 * @LastEditTime: 2021-08-16 06:55:34
 */
import 'package:flutter/material.dart';

class CustomTile extends StatelessWidget {
  const CustomTile({Key key, this.title, this.tap}) : super(key: key);
  final String title;
  final VoidCallback tap;

  @override
  Widget build(BuildContext context) => Row(
        mainAxisAlignment: MainAxisAlignment.spaceBetween,
        children: [
          Text(
            title,
            style: TextStyle(
              fontSize: 18,
            ),
          ),
          Material(
            color: Colors.transparent,
            child: InkWell(
              borderRadius: BorderRadius.circular(20),
              splashColor: Theme.of(context).primaryColor,
              onTap: tap,
              child: Container(
                width: 44,
                alignment: Alignment(0, 0),
                height: 20,
                decoration: BoxDecoration(
                  color: Color(0xffF3F3F3).withOpacity(0.9),
                  borderRadius: BorderRadius.circular(20),
                ),
                child: Text(
                  "更多",
                  textAlign: TextAlign.center,
                  style: TextStyle(
                    fontSize: 10,
                    color: Color(0xffA0A0A0),
                    height: 1.3,
                  ),
                ),
              ),
            ),
          ),
        ],
      );
}
